home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part1 / 6805 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  857 b 

  1. Path: cyberoptics.com!usenet
  2. From: Greg Parks <gparks@cyberoptics.com>
  3. Newsgroups: comp.lang.c++
  4. Subject: Template class output is ambigous
  5. Date: 19 Feb 1996 20:58:36 GMT
  6. Organization: CyberOptics Corporation
  7. Message-ID: <4gao9s$553@hagar.cyberoptics.com>
  8. NNTP-Posting-Host: jafar.cyberoptics.com
  9. Mime-Version: 1.0
  10. Content-Type: text/plain; charset=us-ascii
  11. Content-Transfer-Encoding: 7bit
  12. X-Mailer: Mozilla 1.2N (Windows; I; 32bit)
  13.  
  14. I have a Template class Tuple and a derived class Vector, both 
  15. have defined the insertion operator.  Now I have an array of 
  16. Vector<double> and I want to output an element.
  17.     cout << mark[x];  
  18. But this gives me an 'abiguous operator' error in VC++ 4.0.  
  19. Why?  The help says to cast in order to aboid this, but it 
  20. doesn't work.  What's up with that?  Is this a bug?  Is there a 
  21. workaround?  Am I doing something wrong?
  22.  
  23.